<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>管理系统</title>
  <style>
    body {
      background: #d3d3d3;
      color: darkgray;
      font-family: "Arial", sans-serif;
    }

    .welcome-container {
      display: flex;
      justify-content: center;
      align-items: center;
      height: 100vh;
      text-align: center;
      flex-direction: column;
    }

    .welcome-container h1 {
      font-size: 48px;
      font-weight: bold;
      margin-bottom: 10px;
    }

    .welcome-container p {
      font-size: 20px;
      margin-bottom: 20px;
    }

    .layui-btn-primary:hover {
      background-color: #fff;
      color: #2575fc;
      border: 2px solid #fff;
    }

    .layui-btn-primary {
      border: 2px solid #fff;
      color: #fff;
      font-size: 16px;
    }
  </style>
</head>
<body>
<div class="welcome-container">
  <h1>欢迎来到 OnePiece 管理系统</h1>
  <p>高效管理,简约操作,助力企业迈向新高度</p>
  <button class="layui-btn layui-btn-primary layui-btn-lg" id="explore-btn"
          data-id="47" data-title="个人中心"
          data-url="rbac/user/info.html/">
    开始探索
  </button>
</div>
</body>

<script src="/static/component/pear/module/extends/toast.js"></script>
<script>
  layui.use(['toast', 'carousel', 'element'], function () {
    let $ = layui.jquery,
      element = layui.element,
      carousel = layui.carousel,
      toast = layui.toast;

    $("body").on("click", "[data-url]", function () {
      PearAdmin.changePage({
        id: $(this).attr("data-id"),
        title: $(this).attr("data-title"),
        url: $(this).attr("data-url"),
        type: "_iframe",
      });
    })

    // 点击按钮时显示欢迎消息
    document.getElementById("explore-btn").addEventListener("click", function () {
      toast.info({
        message: '欢迎体验 OnePiece 管理系统',
        position: 'topRight'
      });
      // window.location.href = 'rbac/user/info.html/'
    });
  });
</script>
</html>